<template>
	<view class="pr">
		<image :src="data.poster_img||''" class="w-max db" mode="widthFix"></image>
		<u-navbar :border-bottom="false" title="邀请好友" titleColor="#fff" :background="{ background: '#0000' }"
			immersive />
		<view class="pa top0 left0 w-max ">
			<view class="" style="height: 35vh;"></view>
			<view class="flex-col row-center col-center">
				<!-- #ifdef MP-WEIXIN -->
				<image :src="data.qrcode" class="w400 h400 radius20" show-menu-by-longpress />
				<!-- #endif -->
				<!-- #ifndef MP-WEIXIN -->
				<view class="radius20 bg-fff p20">
					<z-qrcode  :text="data.url" size="400" />
				</view>
				<view class="mt20 fs30" @click="$tool.copy(data.regcode)">邀请码:{{data.regcode}}</view>
				<view class="mt60 td-b" @click="$tool.copy(data.url)">复制链接</view>
				<!-- #endif -->
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				data: '',
			};
		},
		onLoad() {
			this.getData()
		},
		methods: {
			getData() {
				this.$request('/member/team/invite', {
					...this.$params,
					...uni.getSystemInfoSync()
				}).then(res => {
					this.data = res.data
				})
			},
		}
	}
</script>

<style lang="scss">

</style>